package ex03;
import java.util.Scanner;
public class Test3 {

	public static void main(String[] args) {
		// TODO 自动生成的方法存根
		String x;
		String u[];
		int b[];
		Scanner sc=new Scanner(System.in);
		x=sc.next();
		Tongji3 a=new Tongji3();	
		String y[]=x.split(",");
		for(int i=0;i<y.length;i++){
			char c[]=new char[y[i].length()];
			c=a.Abc(y[i]);
			for(int j=0;j<c.length;j++){				
					System.out.print(c[j]);
			}
			System.out.println();
		}
		System.out.println('\n'+"---------");
		u=a.tongji(x);
		b=a.getA();
		for(int i=0;i<u.length;i++){
			if(u[i]!="Z"){
				System.out.println("有"+b[i]+"个"+u[i]+"文件");
			}
		}
	}

}
